package com.itheima.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.itheima.pojo.RoleUser;
import org.apache.ibatis.annotations.Delete;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select;

public interface RoleUserMapper extends BaseMapper<RoleUser> {
    @Delete("delete  from t_role_user where role_id = #{id}")
    boolean deleteUserIds(@Param("id") Long id);

    @Select("select user_id from t_role_user where role_id = #{id}")
    Long[] findUsers(@Param("id") Long id);
}
